home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Language/OS - Multiplatform Resource Library
/
LANGUAGE OS.iso
/
ptolemy
/
patch_04.lha
/
PATCH-0.4.1
/
patch_pt-0.4.1
< prev
next >
Wrap
Text File
|
1993-07-26
|
110KB
|
3,673 lines
*** ./config-hppa.mk Mon Apr 19 04:05:04 1993
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/config-hppa.mk Wed Apr 14 13:40:24 1993
***************
*** 0 ****
--- 1,41 ----
+ # Configuration makefile to make on an HP-PA machine (7xx or 8xx)
+ # running HP-UX with g++2.3.3.u1 or later. The debug format is the
+ # one invented by Utah (HP's format is proprietary) so you will need
+ # gdb to debug.
+ #
+ # @(#)config-hppa.mk 1.4 4/13/93
+ # Copyright (c) 1993 The Regents of the University of California.
+ # All Rights Reserved.
+ #
+ # Programmer: J. T. Buck
+
+ # Get the g++ definitions; we override some below.
+ include $(ROOT)/config-g++.mk
+
+ GPPFLAGS=-DUSG -g $(MEMLOG)
+
+ # Use gcc
+ CC=gcc
+ CFLAGS=-DUSG -g
+
+ # The following is temporary until the problem with LINK_LIBGCC_SPECIAL
+ # is cleared up -- must pass dir with libg++.a to linker
+ GNULIBDIR=/home/gnu/lib
+ LINKFLAGS=-L$(LIBDIR) -L$(GNULIBDIR)
+
+ # If the X11 include directories are in /usr/include/X11, leave
+ # the following symbol blank. Otherwise define it as "-Idir" where
+ # dir is the PARENT of the include directory, which must end in X11.
+ # (this value says to use the headers we stick in with the distribution).
+ X11INCL = -I$(ROOT)/src/compat
+
+ # If the X11 libraries are not on the standard library search path,
+ # define the following symbol as "-Ldir" where dir is the directory
+ # containing them. Otherwise leave it blank.
+ # (you may need to change this)
+ X11LIBDIR = -L/usr/lib/X11R5
+
+ # Tcl symbols
+ TCL_ROOT = $(ROOT)/tcl
+ TCL_H_DIR = $(TCL_ROOT)/include
+ TCL_LIBDIR = $(TCL_ROOT)/lib.$(ARCH)
*** ./src/kernel/Display.cc Mon Dec 7 16:42:44 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Display.cc Mon Apr 12 17:49:45 1993
***************
*** 1,7 ****
static const char file_id[] = "Display.cc";
/**************************************************************************
Version identification:
! @(#)Display.cc 1.24 12/7/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "Display.cc";
/**************************************************************************
Version identification:
! @(#)Display.cc 1.25 4/10/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 71,76 ****
--- 71,77 ----
#include <math.h>
#include "streamCompat.h"
#include "paths.h"
+ #include "SimControl.h"
// constructor initializes streams and filenames
XGraph :: XGraph () : strm(0), tmpFileNames(0), count(0), blockIamIn(0), ng(0)
***************
*** 201,206 ****
--- 202,208 ----
count[didx]++;
fcheck(x,dataSet);
fcheck(y,dataSet);
+ if (SimControl::haltRequested()) return;
if (count[didx] >= nIgnore && strm[didx]) {
if (ascii) {
fprintf(strm[didx], "%g %g\n", x, y);
*** ./src/kernel/EventHorizon.h Mon Dec 7 15:21:04 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/EventHorizon.h Mon Apr 12 17:49:45 1993
***************
*** 16,22 ****
/**************************************************************************
Version identification:
! @(#)EventHorizon.h 2.14 12/7/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 16,22 ----
/**************************************************************************
Version identification:
! @(#)EventHorizon.h 2.15 2/20/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 75,81 ****
// SDFfromUniversal: public FromUniversal, public OutSDFPort
// SDFToUniversal::SDFToUniversal() : ToEventHorizon(this) {...}
! EventHorizon(PortHole* self): selfPort(self) {}
// virtual destructor
virtual ~EventHorizon();
--- 75,82 ----
// SDFfromUniversal: public FromUniversal, public OutSDFPort
// SDFToUniversal::SDFToUniversal() : ToEventHorizon(this) {...}
! EventHorizon(PortHole* self): selfPort(self), ghostPort(0), wormhole(0)
! {}
// virtual destructor
virtual ~EventHorizon();
*** ./src/kernel/Geodesic.h Wed Nov 25 20:43:37 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Geodesic.h Mon Apr 12 17:49:46 1993
***************
*** 7,13 ****
/****************************************************************
Version identification:
! @(#)Geodesic.h 2.11 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 7,13 ----
/****************************************************************
Version identification:
! @(#)Geodesic.h 2.12 4/10/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 118,123 ****
--- 118,127 ----
// return the number of initial particles
int numInit() const {return numInitialParticles;}
+
+ // access head and tail of queue
+ Particle* head() const { return pstack.head();}
+ Particle* tail() const { return pstack.tail();}
// Information printing
StringList print(int verbose = 0) const;
*** ./src/kernel/Histogram.cc Wed Nov 25 20:39:00 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Histogram.cc Mon Apr 12 17:49:46 1993
***************
*** 1,7 ****
static const char file_id[] = "Histogram.cc";
/**************************************************************************
Version identification:
! @(#)Histogram.cc 2.8 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "Histogram.cc";
/**************************************************************************
Version identification:
! @(#)Histogram.cc 2.9 2/20/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 127,140 ****
}
void XHistogram :: terminate() {
! int count;
! double binCtr;
! int binno = 0;
! while (hist->getData (binno, count, binCtr)) {
! display->addPoint (binCtr, float(count));
! binno++;
}
- display->terminate();
LOG_DEL; delete hist;
hist = 0;
LOG_DEL; delete [] optstring;
--- 127,142 ----
}
void XHistogram :: terminate() {
! if (numCounts() > 0) {
! int count;
! double binCtr;
! int binno = 0;
! while (hist->getData (binno, count, binCtr)) {
! display->addPoint (binCtr, float(count));
! binno++;
! }
! display->terminate();
}
LOG_DEL; delete hist;
hist = 0;
LOG_DEL; delete [] optstring;
*** ./src/kernel/Linker.cc Mon Dec 7 16:42:48 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Linker.cc Wed Apr 14 15:28:49 1993
***************
*** 1,7 ****
static const char file_id[] = "Linker.cc";
/**************************************************************************
Version identification:
! @(#)Linker.cc 2.25 12/7/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "Linker.cc";
/**************************************************************************
Version identification:
! @(#)Linker.cc 2.26 4/14/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 167,173 ****
// to permit easy interfacing with Tcl.
int Linker::multiLink (int argc, char** argv) {
! if (!symTableName) {
Error::abortRun ("Incremental linking disabled");
return FALSE;
}
--- 167,178 ----
// to permit easy interfacing with Tcl.
int Linker::multiLink (int argc, char** argv) {
! if (linkingNotSupported) {
! Error::abortRun ("Sorry, incremental linking is not yet ",
! "supported on this architecture");
! return FALSE;
! }
! else if (!symTableName) {
Error::abortRun ("Incremental linking disabled");
return FALSE;
}
*** ./src/kernel/Linker.sysdep.h Wed Nov 25 20:44:25 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Linker.sysdep.h Wed Apr 14 15:28:59 1993
***************
*** 1,6 ****
/**************************************************************************
Version identification:
! @(#)Linker.sysdep.h 2.8 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,6 ----
/**************************************************************************
Version identification:
! @(#)Linker.sysdep.h 2.9 4/14/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 30,36 ****
--- 30,48 ----
This file defines the system-dependent cruft needed for incremental
linking.
+
+ The stuff for HP is not yet completed, hence linkingNotSupported is
+ true.
+
**************************************************************************/
+
+ // Is linking supported? Currently not complete for HP/UX.
+ const int linkingNotSupported =
+ #ifdef hpux
+ 1;
+ #else
+ 0;
+ #endif
// The loader should do incremental linking; use a 4.3/Sun-style loader
// or use the Gnu loader.
*** ./src/kernel/Particle.cc Wed Nov 25 20:39:59 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Particle.cc Mon Apr 12 17:49:47 1993
***************
*** 1,7 ****
static const char file_id[] = "Particle.cc";
/**************************************************************************
Version identification:
! @(#)Particle.cc 2.17 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "Particle.cc";
/**************************************************************************
Version identification:
! @(#)Particle.cc 2.19 4/10/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 207,218 ****
int ComplexParticle :: operator == (const Particle& p) {
if (!typesEqual(p)) return 0;
! Complex pdata = Complex(data);
! return data.real() == pdata.real() &&
! data.imag() == pdata.imag();
}
-
DataType ComplexParticle :: type() const {return COMPLEX;}
// Cast to an int, double, Complex
--- 207,215 ----
int ComplexParticle :: operator == (const Particle& p) {
if (!typesEqual(p)) return 0;
! return data == Complex(p);
}
DataType ComplexParticle :: type() const {return COMPLEX;}
// Cast to an int, double, Complex
***************
*** 248,258 ****
// created object.
ParticleStack :: ~ParticleStack () {
! if (!head) return;
Particle* p;
! while (head->link) {
! p = head;
! head = head->link;
LOG_DEL; delete p;
}
}
--- 245,255 ----
// created object.
ParticleStack :: ~ParticleStack () {
! if (!pHead) return;
Particle* p;
! while (pHead->link) {
! p = pHead;
! pHead = pHead->link;
LOG_DEL; delete p;
}
}
***************
*** 261,269 ****
// the last one)
void ParticleStack :: freeup () {
Particle* p;
! while (head) {
! p = head;
! head = head->link;
p->die();
}
}
--- 258,266 ----
// the last one)
void ParticleStack :: freeup () {
Particle* p;
! while (pHead) {
! p = pHead;
! pHead = pHead->link;
p->die();
}
}
***************
*** 273,279 ****
Plasma* p = plasmaList;
while (p) {
! DataType dt = p->head->type();
if (t == dt) return p;
p = p->nextPlasma;
}
--- 270,276 ----
Plasma* p = plasmaList;
while (p) {
! DataType dt = p->type();
if (t == dt) return p;
p = p->nextPlasma;
}
*** ./src/kernel/ParticleStack.h Wed Nov 25 20:44:52 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/ParticleStack.h Mon Apr 12 17:49:47 1993
***************
*** 2,8 ****
#define _ParticleStack_h
/***************************************************************
Version identification:
! @(#)ParticleStack.h 2.3 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 2,8 ----
#define _ParticleStack_h
/***************************************************************
Version identification:
! @(#)ParticleStack.h 2.4 4/10/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 56,71 ****
public:
// put a particle onto the stack
void put(Particle* p) {
! if (!head) tail = p;
! p->link = head; head = p;
}
// get a particle from the stack.
// derived classes must do the empty-stack check!
! // if we get the last, tail will still point to it.
Particle* get() {
! Particle* p = head;
! head = p->link;
return p;
}
--- 56,73 ----
public:
// put a particle onto the stack
void put(Particle* p) {
! if (!pHead) pTail = p;
! p->link = pHead; pHead = p;
}
// get a particle from the stack.
// derived classes must do the empty-stack check!
! // if we get the last, pTail will still point to it.
! // however, tail() will correctly return null.
!
Particle* get() {
! Particle* p = pHead;
! pHead = p->link;
return p;
}
***************
*** 72,91 ****
// put an article on the "tail" of the stack (to use the
// stack like a queue)
void putTail(Particle* p) {
! if (head) tail->link = p;
! else head = p; // first particle
! tail = p; // point to new last particle
p->link = 0; // terminate the chain
}
// empty stack check
! int empty() const { return head ? 0 : 1;}
// return true if more than one member (for Plasma)
! int moreThanOne() const { return (head && head->link) ? 1 : 0;}
// constructor (built with 0 or one particle)
! ParticleStack(Particle*h) : head(h), tail(h) {
// make sure the stack is "terminated"
if (h) h->link = 0;
}
--- 74,93 ----
// put an article on the "tail" of the stack (to use the
// stack like a queue)
void putTail(Particle* p) {
! if (pHead) pTail->link = p;
! else pHead = p; // first particle
! pTail = p; // point to new last particle
p->link = 0; // terminate the chain
}
// empty stack check
! int empty() const { return pHead ? 0 : 1;}
// return true if more than one member (for Plasma)
! int moreThanOne() const { return (pHead && pHead->link) ? 1 : 0;}
// constructor (built with 0 or one particle)
! ParticleStack(Particle*h) : pHead(h), pTail(h) {
// make sure the stack is "terminated"
if (h) h->link = 0;
}
***************
*** 95,103 ****
// return all Particles to their Plasmas
void freeup ();
! protected:
! Particle* head;
private:
! Particle* tail;
};
#endif
--- 97,110 ----
// return all Particles to their Plasmas
void freeup ();
!
! // return ptr to head, tail respectively.
! Particle* head() const { return pHead;}
! // note that for an empty stack, pTail may not be 0,
! // hence the following code:
! Particle* tail() const { return pHead ? pTail : 0;}
private:
! Particle* pHead;
! Particle* pTail;
};
#endif
*** ./src/kernel/PortHole.cc Thu Dec 10 12:47:14 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/PortHole.cc Mon Apr 12 17:49:49 1993
***************
*** 17,23 ****
/**************************************************************************
Version identification:
! @(#)PortHole.cc 2.43 12/10/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 17,23 ----
/**************************************************************************
Version identification:
! @(#)PortHole.cc 2.45 4/10/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 511,521 ****
Particle** p = myBuffer->next();
// Initialize particles on the buffer, so when we
// restart they do not contain old data
! (*p)->initialize();
}
// If this is an output PortHole (or connected to an
// input porthole), initialize myGeodesic
! if(myGeodesic && (isItOutput() || (!asEH() && atBoundary())))
myGeodesic->initialize();
}
--- 511,524 ----
Particle** p = myBuffer->next();
// Initialize particles on the buffer, so when we
// restart they do not contain old data
! // fill in any empty holes (which could be caused by
! // errors of some kinds in previous runs).
! if (*p) (*p)->initialize();
! else *p = myPlasma->get();
}
// If this is an output PortHole (or connected to an
// input porthole), initialize myGeodesic
! if (far() && myGeodesic && (isItOutput() || (!asEH() && atBoundary())))
myGeodesic->initialize();
}
*** ./src/kernel/PortHole.h Wed Nov 25 20:45:03 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/PortHole.h Mon Apr 12 17:49:49 1993
***************
*** 14,20 ****
/**************************************************************************
Version identification:
! @(#)PortHole.h 2.25 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 14,20 ----
/**************************************************************************
Version identification:
! @(#)PortHole.h 2.26 2/17/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 359,366 ****
// class identification
int isA(const char*) const;
! // am I at wormhole boundary?
! int atBoundary() const { return (isItInput() == far()->isItInput()); }
// Return me as an eventHorizon
virtual EventHorizon* asEH();
--- 359,371 ----
// class identification
int isA(const char*) const;
! // am I at wormhole boundary? Disconnected ports return true,
! // since we implement clusters that way (disconnected ports
! // represent the cluster boundary)
!
! int atBoundary() const {
! return (far() ? (isItInput() == far()->isItInput()) : TRUE);
! }
// Return me as an eventHorizon
virtual EventHorizon* asEH();
*** ./src/kernel/Plasma.h Wed Nov 25 20:44:56 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/Plasma.h Mon Apr 12 17:49:48 1993
***************
*** 6,12 ****
#endif
/**************************************************************************
Version identification:
! @(#)Plasma.h 1.7 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 6,12 ----
#endif
/**************************************************************************
Version identification:
! @(#)Plasma.h 1.8 4/10/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 71,79 ****
p->initialize();
return p;
}
! else return head->useNew();
}
! DataType type() { return head->type();}
// constructor -- all objs built are added to the static linked list.
Plasma(Particle& p) : ParticleStack(&p), nextPlasma(plasmaList) {
--- 71,79 ----
p->initialize();
return p;
}
! else return head()->useNew();
}
! DataType type() { return head()->type();}
// constructor -- all objs built are added to the static linked list.
Plasma(Particle& p) : ParticleStack(&p), nextPlasma(plasmaList) {
*** ./src/kernel/makefile Thu Dec 10 15:52:02 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/makefile Mon Apr 12 17:49:50 1993
***************
*** 187,193 ****
DataStruct.o : DataStruct.cc DataStruct.h type.h logNew.h
Display.o : Display.cc Display.h type.h logNew.h miscFuncs.h Error.h StringList.h \
DataStruct.h Block.h NamedObj.h isa.h PortHole.h dataType.h Particle.h ComplexSubset.h \
! Attribute.h State.h streamCompat.h paths.h
DoubleLink.o : DoubleLink.cc DoubleLink.h type.h logNew.h
Domain.o : Domain.cc Domain.h StringList.h miscFuncs.h logNew.h DataStruct.h \
type.h Star.h Block.h NamedObj.h isa.h PortHole.h dataType.h Particle.h ComplexSubset.h \
--- 187,193 ----
DataStruct.o : DataStruct.cc DataStruct.h type.h logNew.h
Display.o : Display.cc Display.h type.h logNew.h miscFuncs.h Error.h StringList.h \
DataStruct.h Block.h NamedObj.h isa.h PortHole.h dataType.h Particle.h ComplexSubset.h \
! Attribute.h State.h streamCompat.h paths.h SimControl.h
DoubleLink.o : DoubleLink.cc DoubleLink.h type.h logNew.h
Domain.o : Domain.cc Domain.h StringList.h miscFuncs.h logNew.h DataStruct.h \
type.h Star.h Block.h NamedObj.h isa.h PortHole.h dataType.h Particle.h ComplexSubset.h \
*** ./src/kernel/pt_fstream.cc Wed Nov 25 21:39:21 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/pt_fstream.cc Mon Apr 12 17:49:50 1993
***************
*** 26,32 ****
*/
// Programmer: J. Buck, Kennard
! // @(#)pt_fstream.cc 1.6 11/25/92
// This defines derived types of ifstream and ofstream that do the following:
--- 26,32 ----
*/
// Programmer: J. Buck, Kennard
! // @(#)pt_fstream.cc 1.8 4/8/93
// This defines derived types of ifstream and ofstream that do the following:
***************
*** 68,89 ****
// check for special file names
// This uses the hardcoded descriptors 0,1,2. These are appropriate
// for UNIX only.
! static int check_special(const char *name, int *pNobufB) {
! int fd = -1, bufB = TRUE;
! /*IF*/ if ( strcmp(name,"<cin>")==0 || strcmp(name,"<stdin>")==0 ) {
! fd = 0;
! } else if ( strcmp(name,"<cout>")==0 || strcmp(name,"<stdout>")==0 ) {
! fd = 1;
! bufB = FALSE;
! } else if ( strcmp(name,"<cerr>")==0 || strcmp(name,"<stderr>")==0 ) {
! fd = 2;
! bufB = FALSE;
! } else if ( strcmp(name,"<clog>")==0 || strcmp(name,"<stdlog>")==0 ) {
! fd = 2;
}
! if ( pNobufB )
! *pNobufB = ! bufB;
return fd;
}
--- 68,99 ----
// check for special file names
// This uses the hardcoded descriptors 0,1,2. These are appropriate
// for UNIX only.
! static int check_special(const char *name, int &nobufB) {
! int fd = -1;
! nobufB = FALSE;
! // see if we begin with "<c" or "<std". If so, skip prefix, else
! // exit immediately.
! if (*name != '<') return fd;
! if (name[1] == 'c') name += 2;
! else if (strncmp(name+1,"std", 3) == 0) name += 4;
! else return -1;
!
! // look for remainder of standard names.
! if (strcmp(name,"in>") == 0)
! fd = 0;
! else if (strcmp(name,"out>") == 0)
! {
! fd = 1;
! nobufB = TRUE;
}
! else if ( strcmp(name,"err>")==0)
! {
! fd = 2;
! nobufB = TRUE;
! }
! else if ( strcmp(name,"log>")==0)
! fd = 2;
return fd;
}
***************
*** 91,103 ****
open(name,mode,prot);
}
void pt_ifstream::open(const char* name, int mode, int prot) {
! int nobufB;
! int fd = check_special(name, &nobufB);
! if ( fd >= 0 ) rdbuf()->attach(fd);
! else ifstream::open(expand(name),mode,prot);
! if (!*this) reportError("reading");
! if (nobufB) setf(unitbuf);
}
pt_ofstream::pt_ofstream(const char *name,int mode, int prot) {
--- 101,120 ----
open(name,mode,prot);
}
+ // open file, treating some names as special.
+
void pt_ifstream::open(const char* name, int mode, int prot) {
! int nobufB;
! int fd = check_special(name, nobufB);
! if (fd == 0) rdbuf()->attach(fd);
! else if (fd > 0) {
! Error::abortRun("Can't open ", name,
! " for reading: write-only file descriptor");
! return;
! }
! else ifstream::open(expand(name),mode,prot);
! if (!*this) reportError("reading");
! if (nobufB) setf(unitbuf);
}
pt_ofstream::pt_ofstream(const char *name,int mode, int prot) {
***************
*** 105,114 ****
}
void pt_ofstream::open(const char* name, int mode, int prot) {
! int nobufB;
! int fd = check_special(name, &nobufB);
! if ( fd >= 0 ) rdbuf()->attach(fd);
! else ofstream::open(expand(name),mode,prot);
if (!*this) reportError("writing");
! if (nobufB) setf(unitbuf);
}
--- 122,136 ----
}
void pt_ofstream::open(const char* name, int mode, int prot) {
! int nobufB;
! int fd = check_special(name, nobufB);
! if (fd == 0) {
! Error::abortRun("Can't open ", name,
! " for writing: can't write to standard input");
! return;
! }
! else if (fd > 0) rdbuf()->attach(fd);
! else ofstream::open(expand(name),mode,prot);
if (!*this) reportError("writing");
! if (nobufB) setf(unitbuf);
}
*** ./src/kernel/pt_fstream.h Wed Nov 25 21:39:20 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/kernel/pt_fstream.h Mon Apr 12 17:49:51 1993
***************
*** 31,37 ****
*/
// Programmer: J. Buck
! // @(#)pt_fstream.h 1.4 11/25/92
// This defines derived types of ifstream and ofstream that do the following:
--- 31,37 ----
*/
// Programmer: J. Buck
! // @(#)pt_fstream.h 1.5 3/30/93
// This defines derived types of ifstream and ofstream that do the following:
***************
*** 43,48 ****
--- 43,54 ----
// (and <stdin>, <stdout> ,<stderr>) are recognized.
//
// Otherwise they are the same as their baseclasses.
+ //
+ // Warning: calling close() on a pt_ofstream that writes to <cerr> will
+ // close the standard error stream, with probably disasterous results.
+ // Calling the destructor, however, will do the right thing. Overriding
+ // close() is not sufficient to solve this because of the design of the
+ // fstream and filebuf classes.
#include <fstream.h>
*** ./src/ptcl/PTcl.cc Tue Dec 1 18:36:31 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/ptcl/PTcl.cc Mon Apr 12 17:47:51 1993
***************
*** 1,6 ****
/**************************************************************************
Version identification:
! @(#)PTcl.cc 1.11 12/1/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,6 ----
/**************************************************************************
Version identification:
! @(#)PTcl.cc 1.12 2/17/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 108,114 ****
PTcl::~PTcl() {
LOG_DEL; delete universe;
removeEntry();
! if (myInterp) { LOG_DEL; delete interp;}
}
// Attach the PTcl to a new universe
--- 108,117 ----
PTcl::~PTcl() {
LOG_DEL; delete universe;
removeEntry();
! if (myInterp) {
! Tcl_DeleteInterp(interp);
! interp = 0;
! }
}
// Attach the PTcl to a new universe
*** ./src/ptcl/ptclError.cc Tue Dec 1 18:42:09 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/ptcl/ptclError.cc Mon Apr 12 17:47:52 1993
***************
*** 1,7 ****
static const char file_id[] = "ptclError.cc";
/*******************************************************************
SCCS Version identification :
! @(#)ptclError.cc 1.8 12/1/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "ptclError.cc";
/*******************************************************************
SCCS Version identification :
! @(#)ptclError.cc 1.9 4/8/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 58,63 ****
--- 58,64 ----
p3(m1,m2,m3);
return;
}
+ // if there is already a result, append to it.
char* res = PTcl::activeInterp->result;
StringList msg;
if (res && *res)
***************
*** 78,97 ****
void
Error :: error (const NamedObj& o, cc* m1, cc* m2, cc* m3) {
! if (PTcl::activeInterp == 0) {
! cerr << "ERROR: ";
! Error::message(o,m1,m2,m3);
! return;
! }
! if (!m2) m2 = "";
! if (!m3) m3 = "";
! StringList s = o.fullName();
! const char* name = s;
! int l = strlen(name) + strlen(m1) + strlen(m2) + strlen(m3) + 10;
! LOG_NEW; char* msg = new char[l];
! sprintf (msg, "ERROR: %s: %s%s%s", name, m1, m2, m3);
! Tcl_SetResult(PTcl::activeInterp, msg, TCL_VOLATILE);
! LOG_DEL; delete msg;
}
void
--- 79,87 ----
void
Error :: error (const NamedObj& o, cc* m1, cc* m2, cc* m3) {
! StringList n_m1 = o.fullName();
! n_m1 << ":" << m1;
! error(n_m1,m2,m3);
}
void
*** ./src/pigilib/compile.c Wed Nov 25 21:25:30 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/compile.c Mon Apr 12 17:50:29 1993
***************
*** 24,30 ****
*/
/* compile.c edg
Version identification:
! @(#)compile.c 1.24 11/25/92
Updates:
4/16/90 = added Oct change lists to keep track of changes so that only
facets that the user changes get compiled.
--- 24,30 ----
*/
/* compile.c edg
Version identification:
! @(#)compile.c 1.25 1/19/93
Updates:
4/16/90 = added Oct change lists to keep track of changes so that only
facets that the user changes get compiled.
***************
*** 44,53 ****
*/
/* Includes */
#include <stdio.h>
#include <strings.h>
#include <errno.h>
- #include "local.h"
#include "rpc.h"
#include "paramStructs.h"
#include "vemInterface.h"
--- 44,53 ----
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <strings.h>
#include <errno.h>
#include "rpc.h"
#include "paramStructs.h"
#include "vemInterface.h"
***************
*** 429,434 ****
--- 429,436 ----
Emits connect, input, and output statements.
*/
#define BLEN 80
+
+ static boolean TermIsMulti();
static boolean
ConnectPass(facetPtr)
*** ./src/pigilib/edit.c Wed Nov 25 21:25:37 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/edit.c Mon Apr 12 17:50:29 1993
***************
*** 24,30 ****
*/
/* edit.c edg
Version identification:
! @(#)edit.c 1.31 11/25/92
*/
--- 24,30 ----
*/
/* edit.c edg
Version identification:
! @(#)edit.c 1.32 1/19/93
*/
***************
*** 94,105 ****
octObject *instPtr;
{
octObject busProp;
- static dmTextItem item = {"Bus Width", 1, 10, NULL, NULL};
-
GetOrInitBusProp(instPtr, &busProp);
return editBusOrDelay(&busProp,"Bus Width","Edit Bus Width");
}
/* EditSogParams 5/27/88
Outputs: return = TRUE if no error.
*/
--- 94,105 ----
octObject *instPtr;
{
octObject busProp;
GetOrInitBusProp(instPtr, &busProp);
return editBusOrDelay(&busProp,"Bus Width","Edit Bus Width");
}
+ static boolean EditParamList();
+
/* EditSogParams 5/27/88
Outputs: return = TRUE if no error.
*/
***************
*** 181,190 ****
EditFormalParams(galFacetPtr)
octObject *galFacetPtr;
{
! ParamType *place;
! int i, width, maxwidth;
ParamListType pList;
- dmTextItem *items;
ERR_IF1(!GetFormalParams(galFacetPtr, &pList));
--- 181,188 ----
EditFormalParams(galFacetPtr)
octObject *galFacetPtr;
{
! int i;
ParamListType pList;
ERR_IF1(!GetFormalParams(galFacetPtr, &pList));
***************
*** 410,416 ****
boolean
OpenPaletteInit()
{
! char *a, *b, *copy, *techDir, buf[FILENAME_MAX];
int i;
/* dots in resource names no longer work??? */
--- 408,414 ----
boolean
OpenPaletteInit()
{
! char *a, *b, *copy, *techDir, buf[MAXPATHLEN];
int i;
/* dots in resource names no longer work??? */
*** ./src/pigilib/err.c Wed Nov 25 21:25:42 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/err.c Mon Apr 12 17:50:30 1993
***************
*** 24,36 ****
*/
/* err.c edg
Version identification:
! @(#)err.c 1.2 11/25/92
Error handling functions.
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#define ERR_BUF_N 1000
--- 24,36 ----
*/
/* err.c edg
Version identification:
! @(#)err.c 1.3 1/19/93
Error handling functions.
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#define ERR_BUF_N 1000
*** ./src/pigilib/exec.c Wed Nov 25 21:25:49 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/exec.c Mon Apr 12 17:50:30 1993
***************
*** 24,37 ****
*/
/* exec.c edg
Version identification:
! @(#)exec.c 1.15 11/25/92
*/
/* Includes */
#include <stdio.h>
#include <strings.h>
- #include "local.h"
#include "rpc.h"
#include "vemInterface.h"
#include "compile.h"
--- 24,37 ----
*/
/* exec.c edg
Version identification:
! @(#)exec.c 1.16 1/19/93
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <strings.h>
#include "rpc.h"
#include "vemInterface.h"
#include "compile.h"
***************
*** 40,45 ****
--- 40,47 ----
#include "edit.h"
#include "err.h"
#include "util.h"
+ #include "ganttIfc.h"
+
#if defined(PTK)
#include "ptk.h" /* Interpreter name, window name, etc. aok */
#include "ptkCalls.h" /* C utilities for using tcl from pigi. aok */
***************
*** 307,314 ****
lsList cmdList;
long userOptionWord;
{
- octObject facet;
-
ViInit("display-schedule");
ErrClear();
FindClear();
--- 309,314 ----
*** ./src/pigilib/ganttIfc.c Wed Nov 25 21:25:58 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/ganttIfc.c Mon Apr 12 17:50:31 1993
***************
*** 24,35 ****
*/
/* ganttIfc.c edg
Version identification:
! @(#)ganttIfc.c 1.7 11/25/92
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#include "rpc.h"
#include "err.h"
#include "ganttIfc.h"
--- 24,35 ----
*/
/* ganttIfc.c edg
Version identification:
! @(#)ganttIfc.c 1.8 1/19/93
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#include "rpc.h"
#include "err.h"
#include "ganttIfc.h"
***************
*** 204,209 ****
--- 204,210 ----
ViDone();
}
+ void
FindAndMarkError(facetP, name)
octObject *facetP;
char *name;
*** ./src/pigilib/ganttIfc.h Wed Nov 25 21:27:48 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/ganttIfc.h Mon Apr 12 17:50:31 1993
***************
*** 24,30 ****
*/
/* ganttIfc.h edg
Version identification:
! @(#)ganttIfc.h 1.2 11/25/92
*/
extern void FrameSetFacet();
--- 24,30 ----
*/
/* ganttIfc.h edg
Version identification:
! @(#)ganttIfc.h 1.3 1/19/93
*/
extern void FrameSetFacet();
***************
*** 34,39 ****
--- 34,40 ----
extern int DestroyFrames();
extern int GanttMan();
extern void GanttErr();
+ extern void FindAndMarkError();
/* Functions below should only be called by GGI */
extern boolean GanttRun();
*** ./src/pigilib/icon.c Mon Dec 7 17:20:39 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/icon.c Mon Apr 12 17:50:32 1993
***************
*** 24,40 ****
*/
/*
icon.c edg
! Version: @(#)icon.c 2.16 12/7/92
*/
/* Includes */
#include <stdio.h>
#include <sys/file.h>
#include <sys/param.h>
#include <sys/stat.h>
#include <pwd.h>
- #include "local.h"
#include "rpc.h"
#include "util.h"
#include "err.h"
--- 24,40 ----
*/
/*
icon.c edg
! Version: @(#)icon.c 2.17 1/19/93
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <sys/file.h>
#include <sys/param.h>
#include <sys/stat.h>
#include <pwd.h>
#include "rpc.h"
#include "util.h"
#include "err.h"
***************
*** 111,136 ****
if (background) strcat(buf, "&");
}
- /* 5/8/90
- Open a window and run xedit (or user selected program) on a file.
- Does not run in the background.
- This routine does not return until program is exited.
- */
- static boolean
- EditFile(fileName)
- char *fileName;
- {
- char buf[512];
- genDispCommand(buf, fileName, 0);
- PrintDebug(buf);
- if (util_csystem(buf)) {
- sprintf(buf, "Cannot edit Ptolemy code file '%s'", fileName);
- ErrAdd(buf);
- return(FALSE);
- }
- return (TRUE);
- }
-
/* 8/3/90
Open a window and run xedit on a file.
Runs in the background and returns immediately.
--- 111,116 ----
***************
*** 512,518 ****
IconFileToSourceFile (iconFile, sourceFile, domain)
char* iconFile, *sourceFile, *domain;
{
! char dir[512], *base, *dom;
int i, n;
strcpy (dir, iconFile);
--- 492,498 ----
IconFileToSourceFile (iconFile, sourceFile, domain)
char* iconFile, *sourceFile, *domain;
{
! char dir[512], *base, *dom = 0;
int i, n;
strcpy (dir, iconFile);
*** ./src/pigilib/kernelCalls.cc Thu Nov 26 00:45:37 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/kernelCalls.cc Mon Apr 12 17:50:32 1993
***************
*** 1,7 ****
static const char file_id[] = "kernelCalls.cc";
/*
Version identification:
! @(#)kernelCalls.cc 2.47 11/26/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "kernelCalls.cc";
/*
Version identification:
! @(#)kernelCalls.cc 2.48 2/17/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 260,265 ****
--- 260,266 ----
const char* dom = KnownBlock::domain();
if (strcmp(dom, oldDom) == 0) return;
LOG << "domain " << dom << "\n";
+ oldDom = dom;
}
// Return the domain of an object: note, it may not be the current
*** ./src/pigilib/local.h Wed Nov 25 21:28:04 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/local.h Mon Apr 12 17:50:33 1993
***************
*** 22,53 ****
ENHANCEMENTS, OR MODIFICATIONS.
COPYRIGHTENDKEY
*/
/* local.h edg
Version identification:
! @(#)local.h 1.4 11/25/92
This is a local include file for useful macros and definitions.
*/
/* boolean data type */
typedef int boolean;
! #define TRUE (1)
! #define FALSE (0)
#define EOS '\0' /* end of string */
! extern char *calloc();
! /*
! extern void free();
! */
#ifdef USG
! extern int sprintf();
#else
! extern char *sprintf();
#endif
/* buffer length constants */
#define MSG_BUF_MAX 512 /* for messages */
- #ifndef FILENAME_MAX
- #define FILENAME_MAX 512 /* for filename paths */
#endif
--- 22,66 ----
ENHANCEMENTS, OR MODIFICATIONS.
COPYRIGHTENDKEY
*/
+ #ifndef _local_h
+ #define _local_h 1
+
/* local.h edg
Version identification:
! @(#)local.h 1.5 1/19/93
This is a local include file for useful macros and definitions.
*/
+ #include "ansi.h"
+ #ifdef HAS_STDARG
+ #include <stddef.h>
+ #define RAW_PTR void *
+ #else
+ #define RAW_PTR char *
+ #endif
+
/* boolean data type */
typedef int boolean;
! #define TRUE 1
! #define FALSE 0
#define EOS '\0' /* end of string */
! extern RAW_PTR calloc ARGS((size_t,size_t));
! extern RAW_PTR malloc ARGS((size_t));
!
! #include <sys/param.h>
!
#ifdef USG
! extern int sprintf ARGS((char*, const char*, ...));
! extern char *getcwd ARGS((char *,size_t));
! #define getwd(foo) getcwd(foo,MAXPATHLEN-1)
#else
! extern char *sprintf ARGS((char*, const char*, ...));
! extern char *getwd ARGS((char *));
#endif
/* buffer length constants */
#define MSG_BUF_MAX 512 /* for messages */
#endif
*** ./src/pigilib/main.c Tue Dec 1 22:46:04 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/main.c Mon Apr 12 17:50:33 1993
***************
*** 24,36 ****
*/
/* main.c edg 5/9/90
Version identification:
! @(#)main.c 2.21 12/1/92
Initialization code for pigiRpc.
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#include "rpc.h"
#include "vemInterface.h"
#include "compile.h"
--- 24,36 ----
*/
/* main.c edg 5/9/90
Version identification:
! @(#)main.c 2.22 1/19/93
Initialization code for pigiRpc.
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#include "rpc.h"
#include "vemInterface.h"
#include "compile.h"
***************
*** 97,102 ****
--- 97,103 ----
{
CompileEnd();
RPCExit(0);
+ return 0;
}
***************
*** 135,140 ****
--- 136,143 ----
{ExitApp, "Other", "exit-pigi"}
};
+ static void welcome_window();
+
long
UserMain(display, spot, cmdList, userOptionWord, array) /* ARGSUSED */
char *display;
***************
*** 177,183 ****
void pr_accum_string();
! welcome_window ()
{
accum_string ("Ptolemy Interactive Graphics Interface\n");
accum_string (pigiVersion);
--- 180,186 ----
void pr_accum_string();
! static void welcome_window ()
{
accum_string ("Ptolemy Interactive Graphics Interface\n");
accum_string (pigiVersion);
*** ./src/pigilib/makefile Thu Oct 22 17:44:15 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/makefile Mon Apr 12 17:50:34 1993
***************
*** 88,154 ****
# Don't add anything after the next line; makedepend will zap it.
# DO NOT DELETE THIS LINE -- make depend depends on it.
! main.o : main.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
compile.h edit.h exec.h util.h icon.h misc.h ganttIfc.h options.h utilities.h \
err.h
! util.o : util.c local.h err.h util.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h octIfc.h \
vemInterface.h
utilities.o : utilities.c ../../octtools/include/rpc.h ../../octtools/include/port.h \
../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h exec.h
! compile.o : compile.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h paramStructs.h \
vemInterface.h util.h err.h main.h octIfc.h octMacros.h
! paramStructs.o : paramStructs.c local.h util.h err.h paramStructs.h
! vemInterface.o : vemInterface.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h octMacros.h
! edit.o : edit.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h ../../octtools/include/oh.h \
paramStructs.h vemInterface.h util.h err.h octIfc.h exec.h
! exec.o : exec.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
! compile.h octIfc.h ../../octtools/include/oh.h edit.h err.h util.h
! err.o : err.c local.h
! ganttChart.o : ganttChart.c local.h err.h vemInterface.h
! ganttIfc.o : ganttIfc.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h ganttIfc.h \
../../octtools/include/oh.h vemInterface.h
! octIfc.o : octIfc.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h paramStructs.h \
err.h util.h octMacros.h mkIcon.h ../../octtools/include/oh.h mkTerm.h
! icon.o : icon.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h util.h err.h \
vemInterface.h octMacros.h palette.h main.h
! misc.o : misc.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
util.h octIfc.h octMacros.h err.h main.h
! mkTerm.o : mkTerm.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h octMacros.h \
../../octtools/include/oh.h mkTerm.h mkIcon.h
! mkIcon.o : mkIcon.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h mkTerm.h \
octIfc.h octMacros.h util.h ../../octtools/include/oh.h vemInterface.h mkIcon.h
! palette.o : palette.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h ../../octtools/include/oh.h \
octMacros.h err.h mkIcon.h util.h octIfc.h
xfunctions.o : xfunctions.c
! options.o : options.c local.h ../../octtools/include/rpc.h ../../octtools/include/port.h \
! ../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
edit.h exec.h util.h icon.h misc.h err.h
kernelCalls.o : kernelCalls.cc kernelCalls.h ../../src/kernel/InterpGalaxy.h \
--- 88,155 ----
# Don't add anything after the next line; makedepend will zap it.
# DO NOT DELETE THIS LINE -- make depend depends on it.
! main.o : main.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
compile.h edit.h exec.h util.h icon.h misc.h ganttIfc.h options.h utilities.h \
err.h
! util.o : util.c local.h ../../octtools/include/ansi.h err.h util.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h octIfc.h \
vemInterface.h
utilities.o : utilities.c ../../octtools/include/rpc.h ../../octtools/include/port.h \
../../octtools/include/oct.h ../../octtools/include/ansi.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h exec.h
! compile.o : compile.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h paramStructs.h \
vemInterface.h util.h err.h main.h octIfc.h octMacros.h
! paramStructs.o : paramStructs.c local.h ../../octtools/include/ansi.h util.h \
! err.h paramStructs.h
! vemInterface.o : vemInterface.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h octMacros.h
! edit.o : edit.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h ../../octtools/include/oh.h \
paramStructs.h vemInterface.h util.h err.h octIfc.h exec.h
! exec.o : exec.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
! compile.h octIfc.h ../../octtools/include/oh.h edit.h err.h util.h ganttIfc.h
! err.o : err.c local.h ../../octtools/include/ansi.h
! ganttChart.o : ganttChart.c local.h ../../octtools/include/ansi.h err.h vemInterface.h
! ganttIfc.o : ganttIfc.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h ganttIfc.h \
../../octtools/include/oh.h vemInterface.h
! octIfc.o : octIfc.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h paramStructs.h \
err.h util.h octMacros.h mkIcon.h ../../octtools/include/oh.h mkTerm.h
! icon.o : icon.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h util.h err.h \
vemInterface.h octMacros.h palette.h main.h
! misc.o : misc.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
util.h octIfc.h octMacros.h err.h main.h
! mkTerm.o : mkTerm.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h octMacros.h \
../../octtools/include/oh.h mkTerm.h mkIcon.h
! mkIcon.o : mkIcon.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h err.h mkTerm.h \
octIfc.h octMacros.h util.h ../../octtools/include/oh.h vemInterface.h mkIcon.h
! palette.o : palette.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h ../../octtools/include/oh.h \
octMacros.h err.h mkIcon.h util.h octIfc.h
xfunctions.o : xfunctions.c
! options.o : options.c local.h ../../octtools/include/ansi.h ../../octtools/include/rpc.h \
! ../../octtools/include/port.h ../../octtools/include/oct.h ../../octtools/include/list.h \
../../octtools/include/copyright.h ../../octtools/include/region.h vemInterface.h \
edit.h exec.h util.h icon.h misc.h err.h
kernelCalls.o : kernelCalls.cc kernelCalls.h ../../src/kernel/InterpGalaxy.h \
*** ./src/pigilib/misc.c Wed Nov 25 21:26:19 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/misc.c Mon Apr 12 17:50:34 1993
***************
*** 24,36 ****
*/
/* misc.c edg
Version identification:
! @(#)misc.c 2.15 11/25/92
*/
/* Includes */
#include <stdio.h>
#include <strings.h>
- #include "local.h"
#include "rpc.h"
#include "vemInterface.h"
#include "util.h"
--- 24,36 ----
*/
/* misc.c edg
Version identification:
! @(#)misc.c 2.18 4/7/93
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <strings.h>
#include "rpc.h"
#include "vemInterface.h"
#include "util.h"
***************
*** 47,52 ****
--- 47,53 ----
/* uses the ptman script to print it out the man page for the given
star or galaxy */
+ boolean
ManPage(starName)
char *starName;
{
***************
*** 128,133 ****
--- 129,139 ----
ViDone();
}
+
+ /***********************************************************************
+ PrintFacet(): calls "prfacet" utility to save PostScript to printer
+ or file.
+ ***********************************************************************/
int
PrintFacet(spot, cmdList, userOptionWord) /* ARGSUSED */
RPCSpot *spot;
***************
*** 134,168 ****
lsList cmdList;
long userOptionWord;
{
! static dmTextItem item = {"Options (e.g. -p -b 3x3):", 1, 40, "-x -X", NULL};
! char buf[512];
! octObject facet;
! char* fullName;
! ViInit("print facet");
! ErrClear();
! facet.objectId = spot->facet;
! if (octGetById(&facet) != OCT_OK) {
! PrintErr(octErrorString());
! ViDone();
! }
! octFullName(&facet,&fullName);
! if (dmMultiText("print facet (PRINTER variable must be set)", 1, &item) != VEM_OK) {
! PrintCon("Aborted entry");
! ViDone();
! }
! sprintf(buf, "prfacet %s %s", item.value, fullName);
! PrintDebug(buf);
! if (util_csystem(buf)) {
! sprintf(buf, "Error invoking prfacet utility.");
! PrintErr(buf);
! }
! ViDone();
! }
int
ERFilterDesign(spot, cmdList, userOptionWord) /* ARGSUSED */
RPCSpot *spot;
--- 140,202 ----
lsList cmdList;
long userOptionWord;
{
! static dmTextItem items[] = {
! {"oct2ps options:", 1, 40, "-x -X -b 3x3", NULL},
! {"(P)rint or to (F)ile:", 1, 40, "P", NULL},
! {"file name:", 1, 40, "", NULL}
! };
! #define ITEMS_N sizeof(items) / sizeof(dmTextItem)
! char buf[512];
! octObject facet;
! char* fullName;
! char fileName[128];
! /** Begin here. **/
! ViInit("print facet");
! ErrClear();
! /** Get facet information. **/
! facet.objectId = spot->facet;
! if (octGetById(&facet) != OCT_OK) {
! PrintErr(octErrorString());
! ViDone();
! }
! octFullName(&facet, &fullName);
+ /** Display dialog box. **/
+ if (dmMultiText("print facet (PRINTER variable must be set)",
+ ITEMS_N, items) != VEM_OK) {
+ PrintCon("Aborted entry");
+ ViDone();
+ }
+ /** Error-check the user input. **/
+ if ((items[1].value[0] == 'f') || (items[1].value[0] == 'F')) {
+ fileName[0] = '\000'; /* Clear previous value. */
+ sscanf(items[2].value, "%s", fileName); /* Get first word. */
+ if (!fileName[0]) {
+ PrintErr("print-facet needs a filename");
+ ViDone();
+ }
+ sprintf(buf, "prfacet -TOFILE %s %s %s", fileName,
+ items[0].value, fullName);
+ } else {
+ sprintf(buf, "prfacet %s %s", items[0].value, fullName);
+ }
+
+ /** Call the prfacet command. **/
+ PrintDebug(buf);
+ if (util_csystem(buf)) {
+ sprintf(buf, "Error invoking prfacet utility.");
+ PrintErr(buf);
+ }
+ ViDone();
+
+ #undef ITEMS_N
+ } /* end PrintFacet() */
+
+
int
ERFilterDesign(spot, cmdList, userOptionWord) /* ARGSUSED */
RPCSpot *spot;
***************
*** 254,259 ****
--- 288,295 ----
ViDone();
}
+ static void AdjustScalePan();
+
/* 6/27/89 = tries to open facet read-only first */
int
RpcOpenFacet(spot, cmdList, userOptionWord) /* ARGSUSED */
***************
*** 272,278 ****
RPCArg *theArg;
Window newWindow; /* the vem window looking at facet */
octBox bbox; /* an argument to octBB, return value not used */
! void AdjustScalePan(); /* this function is right after RpcOpenFacet */
ViInit("open-facet");
ErrClear();
--- 308,314 ----
RPCArg *theArg;
Window newWindow; /* the vem window looking at facet */
octBox bbox; /* an argument to octBB, return value not used */
!
ViInit("open-facet");
ErrClear();
*** ./src/pigilib/mkIcon.c Wed Nov 25 21:26:26 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/mkIcon.c Mon Apr 12 17:50:35 1993
***************
*** 1,6 ****
/* mkIcon.c edg
Version identification:
! @(#)mkIcon.c 1.15 11/25/92
*/
/*
--- 1,6 ----
/* mkIcon.c edg
Version identification:
! @(#)mkIcon.c 1.16 1/19/93
*/
/*
***************
*** 29,37 ****
*/
/* Includes */
#include <stdio.h>
#include <sys/file.h>
- #include "local.h"
#include "rpc.h"
#include "err.h"
#include "mkTerm.h"
--- 29,37 ----
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <sys/file.h>
#include "rpc.h"
#include "err.h"
#include "mkTerm.h"
***************
*** 45,51 ****
#define ERRBUF_MAX 1000
! static octObject starBoxLayer, galBoxLayer, iconBackgrLayer, iconShadowLayer;
/* 8/24/89
Check to see if icon already exists.
--- 45,51 ----
#define ERRBUF_MAX 1000
! static octObject starBoxLayer, galBoxLayer, iconBackgrLayer;
/* 8/24/89
Check to see if icon already exists.
***************
*** 134,140 ****
IconType type;
{
octObject srcFacet;
! char buf[FILENAME_MAX];
char *techDir;
srcFacet.type = OCT_FACET;
--- 134,140 ----
IconType type;
{
octObject srcFacet;
! char buf[MAXPATHLEN];
char *techDir;
srcFacet.type = OCT_FACET;
***************
*** 216,244 ****
}
static boolean
- MkShadow(layerPtr, size)
- octObject *layerPtr;
- int size;
- {
- Shape box;
- struct octPoint corners[2];
- static struct octPoint noTranslate = {0, 0};
- octObject dummy;
-
- box.type = OCT_BOX;
- box.points = corners;
- box.points_n = 2;
-
- corners[0].x = -60;
- corners[0].y = 40;
- corners[1].x = 40;
- corners[1].y = 40-size*25;
-
- ERR_IF1(!PutShape(layerPtr, &dummy, &box, &noTranslate));
- return TRUE;
- }
-
- static boolean
MkLabel(facetPtr, name)
octObject *facetPtr;
char *name;
--- 216,221 ----
***************
*** 380,391 ****
if (ohGetOrCreateLayer(iconFacetPtr, &iconBackgrLayer, "iconBackground")
== OCT_OK) {
ERR_IF1(!MkBox(&iconBackgrLayer, size));
- /* Not making shadows for galaxies
- if (ohGetOrCreateLayer(iconFacetPtr, &iconShadowLayer, "iconShadow")
- == OCT_OK) {
- ERR_IF1(!MkShadow(&iconShadowLayer, size));
- }
- */
}
CK_OCT(ohCreateOrModifyPropStr(iconFacetPtr, &prop, "galaxy", ""));
CK_OCT(octFlushFacet(iconFacetPtr));
--- 357,362 ----
*** ./src/pigilib/mkTerm.c Wed Nov 25 21:26:31 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/mkTerm.c Mon Apr 12 17:50:35 1993
***************
*** 1,6 ****
/* mkTerm.c edg
Version identification:
! @(#)mkTerm.c 1.9 11/25/92
Functions that create terminals and thier symbols in a icon facet.
Functions here use err.c for error handling.
*/
--- 1,6 ----
/* mkTerm.c edg
Version identification:
! @(#)mkTerm.c 1.10 1/19/93
Functions that create terminals and thier symbols in a icon facet.
Functions here use err.c for error handling.
*/
***************
*** 31,38 ****
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#include "rpc.h"
#include "err.h"
#include "octMacros.h"
--- 31,38 ----
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#include "rpc.h"
#include "err.h"
#include "octMacros.h"
*** ./src/pigilib/octIfc.c Wed Nov 25 21:26:38 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/octIfc.c Mon Apr 12 17:50:36 1993
***************
*** 24,38 ****
*/
/* octIfc.c edg
Version identification:
! @(#)octIfc.c 1.22 11/25/92
Useful higher level OCT interface functions.
*/
/* Includes */
#include <stdio.h>
#include <strings.h>
#include <ctype.h>
- #include "local.h"
#include "rpc.h"
#include "paramStructs.h"
#include "err.h"
--- 24,38 ----
*/
/* octIfc.c edg
Version identification:
! @(#)octIfc.c 1.23 1/19/93
Useful higher level OCT interface functions.
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <strings.h>
#include <ctype.h>
#include "rpc.h"
#include "paramStructs.h"
#include "err.h"
***************
*** 44,49 ****
--- 44,51 ----
#include "oct.h"
#include "mkTerm.h"
+ static boolean SetParamProp();
+
/* 8/14/89
Opens the master of an instance, but allows you to choose which facet.
*/
***************
*** 282,287 ****
--- 284,290 ----
return SetParamProp(instPtr,pListPtr,"params");
}
+ boolean
SetTargetParams(instPtr, pListPtr)
octObject *instPtr;
ParamListType *pListPtr;
***************
*** 533,538 ****
--- 536,542 ----
/* get delay, buswidth, or some other property as a string using
* Stringize -- empty string and return of false if not set.
*/
+ boolean
GetStringizedProp(objPtr, name, dest, dlen)
octObject *objPtr;
char *name, *dest;
*** ./src/pigilib/options.c Wed Nov 25 21:26:45 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/options.c Mon Apr 12 17:50:37 1993
***************
*** 24,35 ****
*/
/* options.c edg
Version identification:
! @(#)options.c 1.4 11/25/92
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#include "rpc.h"
#include "vemInterface.h"
#include "edit.h"
--- 24,35 ----
*/
/* options.c edg
Version identification:
! @(#)options.c 1.5 1/19/93
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#include "rpc.h"
#include "vemInterface.h"
#include "edit.h"
*** ./src/pigilib/palette.c Wed Nov 25 21:26:50 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/palette.c Mon Apr 12 17:50:37 1993
***************
*** 1,6 ****
/* palette.c edg
Version identification:
! @(#)palette.c 1.5 11/25/92
Make palette of icons.
These routines should be in octIfc.c maybe, since it enforces policy.
*/
--- 1,6 ----
/* palette.c edg
Version identification:
! @(#)palette.c 1.6 1/19/93
Make palette of icons.
These routines should be in octIfc.c maybe, since it enforces policy.
*/
***************
*** 31,38 ****
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#include "rpc.h"
#include "oh.h"
#include "octMacros.h"
--- 31,38 ----
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#include "rpc.h"
#include "oh.h"
#include "octMacros.h"
***************
*** 115,122 ****
octGenerator genInst;
struct octPoint cursorPt;
! octObject bb;
! char *techDir, buf[FILENAME_MAX], *cell;
octInitGenContents(palFacetPtr, OCT_INSTANCE_MASK, &genInst);
while (octGenerate(&genInst, cursorPtr) == OCT_OK) {
--- 115,122 ----
octGenerator genInst;
struct octPoint cursorPt;
! octBox bb;
! char *techDir, buf[MAXPATHLEN], *cell;
octInitGenContents(palFacetPtr, OCT_INSTANCE_MASK, &genInst);
while (octGenerate(&genInst, cursorPtr) == OCT_OK) {
***************
*** 135,142 ****
/* Locates cursor at an even (100 octUnits) point below the
lowerLeft corner of current bounding box.
*/
! cursorPt.x = AlignFunction(bb.contents.box.lowerLeft.x + 50);
! cursorPt.y = -AlignFunction(-bb.contents.box.lowerLeft.y + 75);
} else {
cursorPt = defaultCursorPt;
}
--- 135,142 ----
/* Locates cursor at an even (100 octUnits) point below the
lowerLeft corner of current bounding box.
*/
! cursorPt.x = AlignFunction(bb.lowerLeft.x + 50);
! cursorPt.y = -AlignFunction(-bb.lowerLeft.y + 75);
} else {
cursorPt = defaultCursorPt;
}
*** ./src/pigilib/paramStructs.c Wed Nov 25 21:26:55 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/paramStructs.c Mon Apr 12 17:50:37 1993
***************
*** 24,30 ****
*/
/* paramStructs.c edg
Version identification:
! @(#)paramStructs.c 1.6 11/25/92
This file contains functions that manage param data structures.
ParamList and param string conversion functions.
Caveats: Need to be able to free allocated memory in ParamListType.
--- 24,30 ----
*/
/* paramStructs.c edg
Version identification:
! @(#)paramStructs.c 1.7 1/19/93
This file contains functions that manage param data structures.
ParamList and param string conversion functions.
Caveats: Need to be able to free allocated memory in ParamListType.
***************
*** 35,43 ****
/* Includes */
#include <stdio.h>
#include <strings.h>
- #include "local.h"
#include "util.h"
#include "err.h"
#include "paramStructs.h"
--- 35,43 ----
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <strings.h>
#include "util.h"
#include "err.h"
#include "paramStructs.h"
*** ./src/pigilib/util.c Wed Nov 25 21:27:01 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/util.c Mon Apr 12 17:50:38 1993
***************
*** 24,39 ****
*/
/* util.c edg
Version identification:
! @(#)util.c 1.9 11/25/92
Utility functions.
*/
/* Includes */
#include <stdio.h>
#include <strings.h>
#include <pwd.h>
#include <search.h>
- #include "local.h"
#include "err.h"
#include "util.h"
#include "rpc.h"
--- 24,39 ----
*/
/* util.c edg
Version identification:
! @(#)util.c 1.10 1/19/93
Utility functions.
*/
/* Includes */
+ #include "local.h"
#include <stdio.h>
#include <strings.h>
#include <pwd.h>
#include <search.h>
#include "err.h"
#include "util.h"
#include "rpc.h"
***************
*** 55,62 ****
char **outPtr;
int bytes;
{
- extern char *malloc();
-
ERR_IF2((*outPtr = (char *) malloc(bytes)) == NULL,
"UMalloc: malloc() failed");
return(TRUE);
--- 55,60 ----
***************
*** 75,82 ****
StrDup(outPtr, in)
char **outPtr, *in;
{
- extern char *malloc();
-
ERR_IF2((*outPtr = (char *) malloc(strlen(in) + 1)) == NULL,
"StrDup: malloc() failed");
(void) strcpy(*outPtr, in);
--- 73,78 ----
***************
*** 94,99 ****
--- 90,96 ----
return(strcpy((char *) calloc(strlen(string)+1, sizeof(char)), string));
}
+ extern char* KcExpandPathName();
/*
Use the ptolemy kernel expansion call -- kennard
***************
*** 275,280 ****
--- 272,278 ----
DupSheet *ds;
{
*ds = NULL;
+ return TRUE;
}
boolean
*** ./src/pigilib/vemInterface.c Wed Nov 25 21:27:15 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigilib/vemInterface.c Mon Apr 12 17:50:39 1993
***************
*** 24,37 ****
*/
/* vemInterface.c edg
Version identification:
! @(#)vemInterface.c 1.8 11/25/92
Functions that interface C to VEM
Note: all print functions append \n to string before printing.
*/
/* Includes */
- #include <stdio.h>
#include "local.h"
#include "rpc.h"
#include "err.h"
#include "octMacros.h"
--- 24,37 ----
*/
/* vemInterface.c edg
Version identification:
! @(#)vemInterface.c 1.9 1/19/93
Functions that interface C to VEM
Note: all print functions append \n to string before printing.
*/
/* Includes */
#include "local.h"
+ #include <stdio.h>
#include "rpc.h"
#include "err.h"
#include "octMacros.h"
*** ./src/libgantt/draw.c Wed Nov 25 20:46:54 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/libgantt/draw.c Mon Apr 12 17:51:16 1993
***************
*** 1,6 ****
/**************************************************************************
Version identification:
! @(#)draw.c 2.3 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,6 ----
/**************************************************************************
Version identification:
! @(#)draw.c 2.4 1/19/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 31,37 ****
**************************************************************************/
#ifndef lint
! static char sccsid[] = "@(#)draw.c 2.3 11/25/92";
#endif /* not lint */
#include <stdio.h>
--- 31,37 ----
**************************************************************************/
#ifndef lint
! static char sccsid[] = "@(#)draw.c 2.4 1/19/93";
#endif /* not lint */
#include <stdio.h>
***************
*** 270,275 ****
--- 270,276 ----
register int proc;
{
register struct star *star;
+ extern GC w_gc_box;
current_gc = w_gc_box;
if (depth>1)
***************
*** 373,379 ****
extern XFontStruct *w_prompt_fontinfo,
*w_100plus_fontinfo,
*w_stat_fontinfo;
! extern GC w_gc_100plus, w_gc_prompt;
XClearWindow(display, w);
--- 374,380 ----
extern XFontStruct *w_prompt_fontinfo,
*w_100plus_fontinfo,
*w_stat_fontinfo;
! extern GC w_gc_100plus, w_gc_prompt, w_gc_stat;
XClearWindow(display, w);
*** ./src/libgantt/read_sched.c Wed Nov 25 20:47:16 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/libgantt/read_sched.c Mon Apr 12 17:51:17 1993
***************
*** 1,6 ****
/**************************************************************************
Version identification:
! @(#)read_sched.c 2.3 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,6 ----
/**************************************************************************
Version identification:
! @(#)read_sched.c 2.4 1/22/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 31,37 ****
**************************************************************************/
#ifndef lint
! static char sccsid[] = "@(#)read_sched.c 2.3 11/25/92";
#endif /* not lint */
#include <stdio.h>
--- 31,37 ----
**************************************************************************/
#ifndef lint
! static char sccsid[] = "@(#)read_sched.c 2.4 1/22/93";
#endif /* not lint */
#include <stdio.h>
***************
*** 88,98 ****
star_list_head = new_star; \
no_nodes++
#define read_stat(name,type,var,msg) \
if (fscanf(inp,"%s",buff)!=1) read_err(msg); \
if (strcmp(buff,name)!=0) read_err(msg); \
! if (fscanf(inp,"%type",&var)!=1) read_err(msg)
--- 88,103 ----
star_list_head = new_star; \
no_nodes++
+ /* name is string to look for
+ type is a format string to read one value, e.g. "%d"
+ var is a variable to read into
+ msg is an error message.
+ */
#define read_stat(name,type,var,msg) \
if (fscanf(inp,"%s",buff)!=1) read_err(msg); \
if (strcmp(buff,name)!=0) read_err(msg); \
! if (fscanf(inp,type,&var)!=1) read_err(msg)
***************
*** 143,149 ****
/* read number of processors */
! read_stat("no_processors",d,no_procs,"displaysched: couldn't read number of processors");
#if DEBUG
printf("Number of processors read by read_sched = %d\n", no_procs);
#endif
--- 148,155 ----
/* read number of processors */
! read_stat("no_processors","%d",no_procs,
! "displaysched: couldn't read number of processors");
#if DEBUG
printf("Number of processors read by read_sched = %d\n", no_procs);
#endif
***************
*** 151,157 ****
/* read the maximum end time (period of the schedule) */
! read_stat("period",d,max_end_time,"displaysched: couldn't read schedule period");
if (max_end_time <= 0) read_err("displaysched: Bad schedule period\n");
/* allocate processor table */
--- 157,164 ----
/* read the maximum end time (period of the schedule) */
! read_stat("period","%d",max_end_time,
! "displaysched: couldn't read schedule period");
if (max_end_time <= 0) read_err("displaysched: Bad schedule period\n");
/* allocate processor table */
***************
*** 255,264 ****
/* read in the summary statistics of the schedule */
! read_stat("min",d,min,"displaysched: could not read MIN");
! read_stat("percentage",lf,percentage,"displaysched: could not read PERCENTAGE");
! read_stat("optimum",lf,optimum,"displaysched: could not read OPTIMUM");
! read_stat("runtime",d,runtime,"displaysched: could not read RUNTIME");
/* try to open the display */
--- 262,274 ----
/* read in the summary statistics of the schedule */
! read_stat("min","%d",min,"displaysched: could not read MIN");
! read_stat("percentage","%lf",percentage,
! "displaysched: could not read PERCENTAGE");
! read_stat("optimum","%lf",optimum,
! "displaysched: could not read OPTIMUM");
! read_stat("runtime","%d",runtime,
! "displaysched: could not read RUNTIME");
/* try to open the display */
*** ./src/pigiRpc/makefile Sat Dec 12 11:30:42 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/pigiRpc/makefile Mon Apr 12 11:37:54 1993
***************
*** 42,48 ****
LIBFILES = $(STAR_LIBFILES) \
$(LIBDIR)/libpigi.a $(LIBDIR)/libptolemy.a $(LIBDIR)/libgantt.a
! VERSION=0.4
ALLSTARS = $(SDFSTARS) $(CGCSTARS) $(CG96STARS) $(CG56STARS) $(CGSTARS) \
$(DDFSTARS) $(CGDDFSTARS) $(THORSTARS) $(DESTARS)
--- 42,48 ----
LIBFILES = $(STAR_LIBFILES) \
$(LIBDIR)/libpigi.a $(LIBDIR)/libptolemy.a $(LIBDIR)/libgantt.a
! VERSION=0.4.1
ALLSTARS = $(SDFSTARS) $(CGCSTARS) $(CG96STARS) $(CG56STARS) $(CGSTARS) \
$(DDFSTARS) $(CGDDFSTARS) $(THORSTARS) $(DESTARS)
*** ./src/ptlang/makefile Tue Nov 24 12:48:38 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/ptlang/makefile Wed Apr 14 13:44:20 1993
***************
*** 1,6 ****
# Makefile for ptolemy language processor
# Version identification:
! # @(#)makefile 2.8 11/24/92
# Copyright (c) 1990 The Regents of the University of California.
# All Rights Reserved.
--- 1,6 ----
# Makefile for ptolemy language processor
# Version identification:
! # @(#)makefile 2.9 4/14/93
# Copyright (c) 1990 The Regents of the University of California.
# All Rights Reserved.
***************
*** 16,22 ****
ptlang: ptlang.o
rm -f ptlang
! cc ptlang.o -o ptlang
ptlang.o: ptlang.c
--- 16,22 ----
ptlang: ptlang.o
rm -f ptlang
! $(CC) ptlang.o -o ptlang
ptlang.o: ptlang.c
*** ./src/domains/sdf/kernel/SDFWormhole.h Wed Nov 25 20:49:59 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/kernel/SDFWormhole.h Mon Apr 12 17:51:42 1993
***************
*** 12,18 ****
/*******************************************************************
SCCS Version identification :
! @(#)SDFWormhole.h 2.11 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 12,18 ----
/*******************************************************************
SCCS Version identification :
! @(#)SDFWormhole.h 2.12 3/16/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 78,86 ****
// return my scheduler
Scheduler* scheduler() const { return target->scheduler();}
! // print methods
! StringList printVerbose() const;
! StringList printRecursive() const;
// clone -- allows interpreter/pigi to make copies
Block* clone() const;
--- 78,85 ----
// return my scheduler
Scheduler* scheduler() const { return target->scheduler();}
! // print method
! StringList print(int verbose) const { return Wormhole::print(verbose);}
// clone -- allows interpreter/pigi to make copies
Block* clone() const;
*** ./src/domains/sdf/kernel/SDFWormhole.cc Wed Nov 25 20:49:29 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/kernel/SDFWormhole.cc Mon Apr 12 17:51:42 1993
***************
*** 1,7 ****
static const char file_id[] = "SDFWormhole.cc";
/******************************************************************
Version identification:
! @(#)SDFWormhole.cc 2.12 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "SDFWormhole.cc";
/******************************************************************
Version identification:
! @(#)SDFWormhole.cc 2.13 3/16/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 93,107 ****
{
buildEventHorizons ();
}
-
- StringList SDFWormhole :: printVerbose() const {
- return Wormhole :: print(0);
- }
-
- StringList SDFWormhole :: printRecursive() const {
- return Wormhole :: print(1);
- }
-
// cloner -- clone the inside and make a new wormhole from that.
Block* SDFWormhole :: clone() const {
--- 93,98 ----
*** ./src/domains/sdf/kernel/SDFCluster.h Mon Nov 30 19:33:17 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/kernel/SDFCluster.h Tue Apr 13 11:11:16 1993
***************
*** 3,9 ****
/**************************************************************************
Version identification:
! @(#)SDFCluster.h 1.19 11/30/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 3,9 ----
/**************************************************************************
Version identification:
! @(#)SDFCluster.h 1.20 1/18/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 162,167 ****
--- 162,170 ----
// generate code using target methods
virtual void genCode(Target&, int depth) = 0;
+ // hook for doing simulated execution of the real stars.
+ virtual void simRunRealStars() = 0;
+
// run/go
int run() = 0;
void go() { run();}
***************
*** 214,222 ****
// optionally do additional clustering on internal cluster
virtual int internalClustering() { return FALSE;}
-
- // hook for doing simulated execution of the real stars.
- virtual void simRunRealStars() = 0;
// print me
virtual ostream& printOn(ostream&) = 0;
--- 217,222 ----
*** ./src/domains/sdf/loopScheduler/LSCluster.cc Wed Nov 25 21:15:12 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/loopScheduler/LSCluster.cc Mon Apr 12 17:53:27 1993
***************
*** 1,7 ****
static const char file_id[] = "LSCluster.cc";
/******************************************************************
Version identification:
! @(#)LSCluster.cc 1.9 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "LSCluster.cc";
/******************************************************************
Version identification:
! @(#)LSCluster.cc 1.10 1/18/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 134,140 ****
static const int FORCE = 2;
// simulate the execution of the cluster
! int LSCluster :: simRunStar(int) {
SDFFiring* f = firing;
while (f) {
--- 134,140 ----
static const int FORCE = 2;
// simulate the execution of the cluster
! void LSCluster :: simRunRealStars() {
SDFFiring* f = firing;
while (f) {
***************
*** 143,149 ****
}
f = f->next;
}
- return 0;
}
// indent by depth tabs.
--- 143,148 ----
*** ./src/domains/sdf/loopScheduler/LSCluster.h Wed Nov 25 21:15:11 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/loopScheduler/LSCluster.h Mon Apr 12 17:53:28 1993
***************
*** 1,6 ****
/******************************************************************
Version identification:
! @(#)LSCluster.h 1.10 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,6 ----
/******************************************************************
Version identification:
! @(#)LSCluster.h 1.11 1/18/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 88,94 ****
// simulate execution for schedule generation. We also
// call simRunStar on the "real" star, so info like the
// maximum # of tokens on each arc will get set right.
! int simRunStar(int deferFiring);
private:
SDFFiring* firing; // local schedule
--- 88,94 ----
// simulate execution for schedule generation. We also
// call simRunStar on the "real" star, so info like the
// maximum # of tokens on each arc will get set right.
! void simRunRealStars();
private:
SDFFiring* firing; // local schedule
*** ./src/domains/sdf/loopScheduler/makefile Fri Oct 23 13:30:26 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/loopScheduler/makefile Mon Apr 12 17:53:28 1993
***************
*** 90,96 ****
DecomGal.h DecomScheduler.h LSGraph.h ../../../../src/domains/sdf/expgraph/ExpandedGraph.h \
../../../../src/domains/sdf/expgraph/EGNode.h ../../../../src/kernel/DoubleLink.h \
../../../../src/domains/sdf/expgraph/EGGate.h ReachabilityMatrix.h LSNode.h \
! LSCluster.h ../../../../src/kernel/Target.h ../../../../src/kernel/streamCompat.h
MergeList.o : MergeList.cc MergeList.h ../../../../src/kernel/DoubleLink.h ../../../../src/kernel/type.h \
../../../../src/kernel/logNew.h LSNode.h ../../../../src/domains/sdf/expgraph/EGNode.h \
../../../../src/domains/sdf/kernel/SDFStar.h ../../../../src/kernel/Star.h ../../../../src/kernel/Block.h \
--- 90,96 ----
DecomGal.h DecomScheduler.h LSGraph.h ../../../../src/domains/sdf/expgraph/ExpandedGraph.h \
../../../../src/domains/sdf/expgraph/EGNode.h ../../../../src/kernel/DoubleLink.h \
../../../../src/domains/sdf/expgraph/EGGate.h ReachabilityMatrix.h LSNode.h \
! LSCluster.h ../../../../src/kernel/Target.h ../../../../src/kernel/pt_fstream.h
MergeList.o : MergeList.cc MergeList.h ../../../../src/kernel/DoubleLink.h ../../../../src/kernel/type.h \
../../../../src/kernel/logNew.h LSNode.h ../../../../src/domains/sdf/expgraph/EGNode.h \
../../../../src/domains/sdf/kernel/SDFStar.h ../../../../src/kernel/Star.h ../../../../src/kernel/Block.h \
*** ./src/domains/sdf/stars/SDFPrinter.pl Tue Dec 8 15:01:59 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/sdf/stars/SDFPrinter.pl Mon Apr 12 17:52:10 1993
***************
*** 2,13 ****
name { Printer }
domain { SDF }
desc {
! Prints out one sample from each input port per line
! If "fileName" is not equal to "<stdout>" (the default), it
! specifies the filename to write to. <stderr> prints on the
! standard error stream.
}
! version {@(#)SDFPrinter.pl 2.11 12/8/92}
author { D. G. Messerschmitt and J. Buck }
copyright {
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
--- 2,13 ----
name { Printer }
domain { SDF }
desc {
! Prints out one sample from each input port per line. The "fileName"
! state specifies the file to be written; the special names <stdout>
! and <cout> (specifying the standard output stream), and <stderr> and <cerr>
! specifying the standard error stream, are also supported.
}
! version {@(#)SDFPrinter.pl 2.12 3/30/93}
author { D. G. Messerschmitt and J. Buck }
copyright {
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
***************
*** 20,25 ****
--- 20,29 ----
This star prints its input, which may be any supported type.
There may be multiple inputs: all inputs are printed together on
the same line, separated by tabs.
+ .pp
+ If output is directed to a file, flushing does not occur until the
+ wrapup method is called. Before the first data are flushed, the file
+ will not even exist. This is normal.
}
inmulti {
name { input }
***************
*** 33,49 ****
}
hinclude { "pt_fstream.h" }
protected {
! pt_ofstream output;
}
wrapup {
! output.close();
}
setup {
! // abortRun is called on open failure
! output.open(fileName);
}
-
go {
MPHIter nexti(input);
PortHole* p;
while ((p = nexti++) != 0)
--- 37,57 ----
}
hinclude { "pt_fstream.h" }
protected {
! pt_ofstream *p_out;
}
+ constructor { p_out = 0;}
+ destructor { LOG_DEL; delete p_out;}
wrapup {
! LOG_DEL; delete p_out;
! p_out = 0;
}
setup {
! // in case file was open from previous run w/o wrapup call
! LOG_DEL; delete p_out;
! LOG_NEW; p_out = new pt_ofstream(fileName);
}
go {
+ pt_ofstream& output = *p_out;
MPHIter nexti(input);
PortHole* p;
while ((p = nexti++) != 0)
*** ./src/domains/de/kernel/DEWormhole.cc Wed Nov 25 20:54:50 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/de/kernel/DEWormhole.cc Mon Apr 12 17:52:38 1993
***************
*** 1,7 ****
static const char file_id[] = "DEWormhole.cc";
/******************************************************************
Version identification:
! @(#)DEWormhole.cc 2.14 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "DEWormhole.cc";
/******************************************************************
Version identification:
! @(#)DEWormhole.cc 2.16 3/16/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 88,93 ****
--- 88,99 ----
LOG_NEW; return new DEWormhole(gal.clone()->asGalaxy(), target->cloneTarget());
}
+ // makeNew, analogous to clone.
+ Block* DEWormhole :: makeNew() const
+ {
+ LOG_NEW; return new DEWormhole(gal.makeNew()->asGalaxy(), target->cloneTarget());
+ }
+
// sumUp(); If the inner domain is timed and stopBeforeDeadlocked,
// put the wormhole into the process queue.
void DEWormhole :: sumUp() {
***************
*** 206,214 ****
}
// send the event
for (int k = numberTokens; k > 0; k--) {
// 3. get the particle
! Particle** p = myBuffer->here();
Particle* pp = myPlasma->get();
*pp = **p;
--- 212,221 ----
}
// send the event
+ myBuffer->backup(numberTokens);
for (int k = numberTokens; k > 0; k--) {
// 3. get the particle
! Particle** p = myBuffer->next();
Particle* pp = myPlasma->get();
*pp = **p;
*** ./src/domains/de/kernel/DEWormhole.h Wed Nov 25 20:55:23 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/de/kernel/DEWormhole.h Mon Apr 12 17:52:38 1993
***************
*** 13,19 ****
/*******************************************************************
SCCS Version identification :
! @(#)DEWormhole.h 2.12 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 13,19 ----
/*******************************************************************
SCCS Version identification :
! @(#)DEWormhole.h 2.13 3/16/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 69,80 ****
// return my scheduler
Scheduler* scheduler() const { return target->scheduler();}
! // print methods
! StringList printVerbose() const { return Wormhole :: print(0);}
! StringList printRecursive() const { return Wormhole :: print(1);}
// clone -- allows interpreter to make copies
Block* clone() const;
// identify myself as a wormhole
int isItWormhole() const { return TRUE;}
--- 69,80 ----
// return my scheduler
Scheduler* scheduler() const { return target->scheduler();}
! // print method
! StringList print(int verbose) const { return Wormhole::print(verbose);}
// clone -- allows interpreter to make copies
Block* clone() const;
+ Block* makeNew() const;
// identify myself as a wormhole
int isItWormhole() const { return TRUE;}
*** ./src/domains/de/stars/DEPrinter.pl Tue Dec 8 15:01:03 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/de/stars/DEPrinter.pl Mon Apr 12 17:52:53 1993
***************
*** 2,14 ****
name { Printer }
domain { DE }
desc {
! Prints out one sample from each input port per line
! If "fileName" is not equal to "<stdout>" (the default), it
! specifies the filename to write to. <stderr> prints on the
! standard error stream.
}
! version { @(#)DEPrinter.pl 2.9 12/8/92}
! author { Soonhoi Ha }
copyright {
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 2,14 ----
name { Printer }
domain { DE }
desc {
! Prints out one sample from each input port per line. The "fileName"
! state specifies the file to be written; the special names <stdout>
! and <cout> (specifying the standard output stream), and <stderr> and <cerr>
! specifying the standard error stream, are also supported.
}
! version { @(#)DEPrinter.pl 2.10 3/30/93}
! author { Soonhoi Ha and J. Buck}
copyright {
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 19,24 ****
--- 19,28 ----
explanation {
The input may be a particle of any type. The print() method
of the particle is used to generate the output.
+ .pp
+ If output is directed to a file, flushing does not occur until the
+ wrapup method is called. Before the first data are flushed, the file
+ will not even exist. This is normal.
}
inmulti {
name { input }
***************
*** 32,45 ****
}
hinclude { "pt_fstream.h" }
protected {
! pt_ofstream output;
}
setup {
! // abortRun is called on open failure
! output.open(fileName);
}
-
go {
// detect which input has an event and print out the
// value and arrivalTime.
InDEMPHIter nextp(input);
--- 36,52 ----
}
hinclude { "pt_fstream.h" }
protected {
! pt_ofstream *p_out;
}
+ constructor { p_out = 0;}
+ destructor { LOG_DEL; delete p_out;}
setup {
! // in case file was open from previous run w/o wrapup call
! LOG_DEL; delete p_out;
! LOG_NEW; p_out = new pt_ofstream(fileName);
}
go {
+ pt_ofstream& output = *p_out;
// detect which input has an event and print out the
// value and arrivalTime.
InDEMPHIter nextp(input);
***************
*** 54,60 ****
}
}
wrapup {
! output.close();
}
}
--- 61,68 ----
}
}
wrapup {
! LOG_DEL; delete p_out;
! p_out = 0;
}
}
*** ./src/domains/ddf/kernel/DDFWormhole.h Wed Nov 25 21:02:15 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/ddf/kernel/DDFWormhole.h Mon Apr 12 17:16:38 1993
***************
*** 11,17 ****
/*******************************************************************
SCCS Version identification :
! @(#)DDFWormhole.h 2.11 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 11,17 ----
/*******************************************************************
SCCS Version identification :
! @(#)DDFWormhole.h 2.12 3/16/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 62,73 ****
Scheduler* scheduler() const { return target->scheduler();}
! // print methods
! StringList printVerbose() const { return Wormhole :: print(0);}
! StringList printRecursive() const { return Wormhole :: print(1);}
// clone -- allows interpreter to make copies
Block* clone() const;
// identify myself as a wormhole
int isItWormhole() const { return TRUE;}
--- 62,73 ----
Scheduler* scheduler() const { return target->scheduler();}
! // print method
! StringList print(int verbose) const { return Wormhole::print(verbose);}
// clone -- allows interpreter to make copies
Block* clone() const;
+ Block* makeNew() const;
// identify myself as a wormhole
int isItWormhole() const { return TRUE;}
*** ./src/domains/ddf/kernel/DDFWormhole.cc Wed Nov 25 21:01:42 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/ddf/kernel/DDFWormhole.cc Mon Apr 12 17:20:51 1993
***************
*** 1,7 ****
static const char file_id[] = "DDFWormhole.cc";
/******************************************************************
Version identification:
! @(#)DDFWormhole.cc 2.10 11/25/92
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
--- 1,7 ----
static const char file_id[] = "DDFWormhole.cc";
/******************************************************************
Version identification:
! @(#)DDFWormhole.cc 2.11 3/16/93
Copyright (c) 1990, 1991, 1992 The Regents of the University of California.
All rights reserved.
***************
*** 78,83 ****
--- 78,90 ----
Block* DDFWormhole :: clone() const
{
LOG_NEW; return new DDFWormhole(gal.clone()->asGalaxy(), target->cloneTarget());
+ }
+
+ // makeNew, analogous to clone.
+ Block* DDFWormhole :: makeNew() const
+ {
+ LOG_NEW; return new DDFWormhole(gal.makeNew()->asGalaxy(),
+ target->cloneTarget());
}
/**************************************************************************
*** ./src/domains/thor/kernel/ThorWormhole.cc Wed Nov 25 20:52:35 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/thor/kernel/ThorWormhole.cc Mon Apr 12 17:54:08 1993
***************
*** 28,34 ****
///////////////////////////////////////////////////////////////////////////
//
// Version identification:
! // @(#)ThorWormhole.cc 1.13 11/25/92
//
// Copyright (c) 1990 The Regents of the University of California,
// All Rights Reserved.
--- 28,34 ----
///////////////////////////////////////////////////////////////////////////
//
// Version identification:
! // @(#)ThorWormhole.cc 1.14 3/16/93
//
// Copyright (c) 1990 The Regents of the University of California,
// All Rights Reserved.
***************
*** 74,79 ****
--- 74,86 ----
Block* ThorWormhole :: clone() const
{
LOG_NEW; return new ThorWormhole(gal.clone()->asGalaxy());
+ }
+
+ // makeNew, analogous to clone.
+ Block* ThorWormhole :: makeNew() const
+ {
+ LOG_NEW; return new ThorWormhole(gal.makeNew()->asGalaxy(),
+ target->cloneTarget());
}
// sumUp(); If the inner domain is timed and stopBeforeDeadlocked,
*** ./src/domains/thor/kernel/ThorWormhole.h Wed Nov 25 20:53:57 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/thor/kernel/ThorWormhole.h Mon Apr 12 17:54:09 1993
***************
*** 33,39 ****
///////////////////////////////////////////////////////////////////////////
//
// Version identification:
! // @(#)ThorWormhole.h 1.11 11/25/92
//
// Copyright (c) 1990 The Regents of the University of California,
// All Rights Reserved.
--- 33,39 ----
///////////////////////////////////////////////////////////////////////////
//
// Version identification:
! // @(#)ThorWormhole.h 1.12 3/16/93
//
// Copyright (c) 1990 The Regents of the University of California,
// All Rights Reserved.
***************
*** 77,88 ****
// destructor
~ThorWormhole() { freeContents();}
! // print methods
! StringList printVerbose() const { return Wormhole :: print(0); }
! StringList printRecursive() const { return Wormhole :: print(1); }
// clone -- allows interpreter to make copies
Block* clone() const;
// return my scheduler
Scheduler* scheduler() const { return target->scheduler();}
--- 77,88 ----
// destructor
~ThorWormhole() { freeContents();}
! // print method
! StringList print(int verbose) const { return Wormhole::print(verbose);}
// clone -- allows interpreter to make copies
Block* clone() const;
+ Block* makeNew() const;
// return my scheduler
Scheduler* scheduler() const { return target->scheduler();}
*** ./src/domains/thor/pepp/make.template Wed Oct 28 21:49:16 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/thor/pepp/make.template Wed Apr 14 13:45:30 1993
***************
*** 1,6 ****
# Makefile for Thor preprocessor (pepp)
# Version identification:
! # @(#)make.template 1.18 10/28/92
# Copyright (c) 1990 The Regents of the University of California.
# All Rights Reserved.
# Date of creation: 2/11/91
--- 1,6 ----
# Makefile for Thor preprocessor (pepp)
# Version identification:
! # @(#)make.template 1.19 4/14/93
# Copyright (c) 1990 The Regents of the University of California.
# All Rights Reserved.
# Date of creation: 2/11/91
***************
*** 43,53 ****
HDRS= comdefs.h cc-strings.h pass1Syn.h
! OBJS = pass1Syn.o pass1Lex.o pass2Lex.o utils.o codefncs.o \
cc-strings.o errmsg.o dbgmsg.o main.o
EXTRA_DESTS= comp.c comp.o pepp
all: makefile $(PROGRAM)
$(PROGRAM): $(OBJS)
--- 43,55 ----
HDRS= comdefs.h cc-strings.h pass1Syn.h
! OBJS = pass1Syn.o pass1Lex.o pass2Lex.o utils.o codefncs.o \
cc-strings.o errmsg.o dbgmsg.o main.o
EXTRA_DESTS= comp.c comp.o pepp
+ C_INCL = -I$(VPATH)
+
all: makefile $(PROGRAM)
$(PROGRAM): $(OBJS)
***************
*** 85,92 ****
install: makefile $(BINDIR)/$(PROGRAM)
$(BINDIR)/$(PROGRAM): $(PROGRAM)
! @echo "Installing $(PROGRAM) in directory $(BINDIR) ...";\
! rm -f $(BINDIR)/$(PROGRAM);\
ln $(PROGRAM) $(BINDIR)
include $(ROOT)/common.mk
--- 87,93 ----
install: makefile $(BINDIR)/$(PROGRAM)
$(BINDIR)/$(PROGRAM): $(PROGRAM)
! rm -f $(BINDIR)/$(PROGRAM)
ln $(PROGRAM) $(BINDIR)
include $(ROOT)/common.mk
***************
*** 93,97 ****
# Don't add anything after the next lin; makedepend will zap it.
# DO NOT DELETE THIS LINE -- make depend depends on it.
-
-
--- 94,96 ----
*** ./src/domains/cg56/stars/CG56Sin.pl Tue Dec 8 15:06:42 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/domains/cg56/stars/CG56Sin.pl Wed Apr 14 13:47:18 1993
***************
*** 6,12 ****
Calculation by table lookup. Input range of (-1,1) scaled by pi.
Output is sin(pi*input).
}
! version { @(#)CG56Sin.pl 1.10 12/8/92 }
acknowledge { Gabriel version by Maureen O'Reilly }
author { Kennard, Chih-Tsung Huang (ported from Gabriel) }
copyright {
--- 6,12 ----
Calculation by table lookup. Input range of (-1,1) scaled by pi.
Output is sin(pi*input).
}
! version { @(#)CG56Sin.pl 1.11 1/19/93 }
acknowledge { Gabriel version by Maureen O'Reilly }
author { Kennard, Chih-Tsung Huang (ported from Gabriel) }
copyright {
***************
*** 75,80 ****
--- 75,88 ----
move y:(r1),b ; read the table
move b1,$ref(output)
}
+ code {
+ // fn to round to nearest int. Done this way because
+ // truncation of negative values to integers is machine
+ // dependent in C/C++.
+ inline int round(double x) {
+ return (x >= 0) ? int(x+0.5) : -int(0.5-x);
+ }
+ }
setup {
double ph = double(phase);
if ( ph < 0 ) {
***************
*** 84,90 ****
int n = (int) floor(ph / 360.0);
ph -= 360.0 * n;
}
! phaseOffset = (int) rint(ph/360.0*256.0);
}
go {
addCode(cbPrepare);
--- 92,98 ----
int n = (int) floor(ph / 360.0);
ph -= 360.0 * n;
}
! phaseOffset = round(ph/360.0*256.0);
}
go {
addCode(cbPrepare);
*** ./src/xgraph/hpgl.c Wed Apr 8 16:06:17 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/xgraph/hpgl.c Wed Apr 14 15:41:03 1993
***************
*** 1,3 ****
--- 1,4 ----
+ /* Ptolemy version: @(#)hpgl.c 1.2 4/14/93 */
/*
* HPGL Output
*
***************
*** 8,16 ****
#define MAPY(state,y) ( MAXY - (y) + P1Y - state->clipminY)
#include "copyright.h"
#include "xgout.h"
#include "plotter.h"
- #include <stdio.h>
#include <math.h>
#define MAX(a,b) ( ((a)>(b)) ? (a) : (b) )
#define MIN(a,b) ( ((a)<(b)) ? (a) : (b) )
--- 9,17 ----
#define MAPY(state,y) ( MAXY - (y) + P1Y - state->clipminY)
#include "copyright.h"
+ #include <stdio.h>
#include "xgout.h"
#include "plotter.h"
#include <math.h>
#define MAX(a,b) ( ((a)>(b)) ? (a) : (b) )
#define MIN(a,b) ( ((a)<(b)) ? (a) : (b) )
*** ./src/xgraph/hard_devices.h Wed Apr 8 16:06:21 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/xgraph/hard_devices.h Wed Apr 14 16:10:27 1993
***************
*** 21,27 ****
char dev_axis_font[MFNAME]; /* Default name of axis font */
double dev_axis_size; /* Default size of axis font (pnts) */
hard_dev_docu dev_docu; /* Document predicate */
! };
extern int hard_count;
extern struct hard_dev hard_devices[];
--- 21,27 ----
char dev_axis_font[MFNAME]; /* Default name of axis font */
double dev_axis_size; /* Default size of axis font (pnts) */
hard_dev_docu dev_docu; /* Document predicate */
! } hard_dev;
extern int hard_count;
extern struct hard_dev hard_devices[];
*** ./src/xgraph/make.template Thu Oct 1 14:41:36 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/src/xgraph/make.template Wed Apr 14 15:41:03 1993
***************
*** 1,6 ****
# Ptolemy-style makefile for xgraph
# Version identification:
! # @(#)make.template 1.3 10/1/92
# Copyright (c) 1991 The Regents of the University of California.
# All Rights Reserved.
--- 1,6 ----
# Ptolemy-style makefile for xgraph
# Version identification:
! # @(#)make.template 1.4 4/14/93
# Copyright (c) 1991 The Regents of the University of California.
# All Rights Reserved.
***************
*** 23,29 ****
xgraph: $(OBJS)
rm -f xgraph
! cc $(X11LIBDIR) -o xgraph $(OBJS) $(LXEXT) $(LX11) -lm
OUT = $(BINDIR)/xgraph
--- 23,29 ----
xgraph: $(OBJS)
rm -f xgraph
! $(CC) $(X11LIBDIR) -o xgraph $(OBJS) $(LXEXT) $(LX11) -lm
OUT = $(BINDIR)/xgraph
*** ./lib/pigiRpcShell Fri Dec 11 14:13:10 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/lib/pigiRpcShell Wed Apr 21 10:54:05 1993
***************
*** 1,6 ****
#! /bin/sh
# usage: pigiRpcShell <vem-rpc-args>
! # Version: @(#)pigiRpcShell 1.3 12/11/92
# Copyright (c) 1990,1991,1992 The Regents of the University of California.
# All Rights Reserved.
#
--- 1,6 ----
#! /bin/sh
# usage: pigiRpcShell <vem-rpc-args>
! # Version: @(#)pigiRpcShell 1.4 1/19/93
# Copyright (c) 1990,1991,1992 The Regents of the University of California.
# All Rights Reserved.
#
***************
*** 17,22 ****
--- 17,24 ----
#
# check if we have an environment-passing file
#
+ # SysV uses LOGNAME instead of USER
+ USER=${USER-$LOGNAME}
cmdfile=/tmp/pigiCmds.$USER
if [ -r $cmdfile ] ; then
. $cmdfile
***************
*** 24,34 ****
libdir=`dirname $0`
PTOLEMY=${PTOLEMY-`dirname $libdir`}
HOME=${HOME-.}
! ARCH=${ARCH-`(/bin/arch || /bin/machine) 2> /dev/null`}
PIGIRPC=${PIGIRPC-$PTOLEMY/bin.$ARCH/pigiRpc}
COMMAND=${COMMAND-$PIGIRPC}
DISPLAY=${DISPLAY-'unix:0'}
TAILARGS=${TAILARGS-''}
export PTOLEMY HOME ARCH PIGIRPC DISPLAY
! chdir $HOME
exec $COMMAND $* $TAILARGS
--- 26,36 ----
libdir=`dirname $0`
PTOLEMY=${PTOLEMY-`dirname $libdir`}
HOME=${HOME-.}
! ARCH=${ARCH-`(/bin/arch || /bin/machine || $PTOLEMY/bin/arch ) 2> /dev/null`}
PIGIRPC=${PIGIRPC-$PTOLEMY/bin.$ARCH/pigiRpc}
COMMAND=${COMMAND-$PIGIRPC}
DISPLAY=${DISPLAY-'unix:0'}
TAILARGS=${TAILARGS-''}
export PTOLEMY HOME ARCH PIGIRPC DISPLAY
! cd $HOME
exec $COMMAND $* $TAILARGS
*** ./bin/pigi Fri Dec 11 22:27:26 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/bin/pigi Thu Apr 15 14:46:59 1993
***************
*** 6,12 ****
#
# This is a modified version to support a PTOLEMY environment variable.
#
! # Version: @(#)pigiEnv.csh 1.4 12/11/92
# Copyright (c) 1990,1991,1992 The Regents of the University of California.
# All Rights Reserved.
#
--- 6,12 ----
#
# This is a modified version to support a PTOLEMY environment variable.
#
! # Version: @(#)pigiEnv.csh 1.5 1/19/93
# Copyright (c) 1990,1991,1992 The Regents of the University of California.
# All Rights Reserved.
#
***************
*** 16,27 ****
exit 1
endif
! if ( ! $?PTOLEMY ) setenv PTOLEMY ~ptolemy
if ( ! $?ARCH ) then
setenv ARCH `$PTOLEMY/bin/arch`
endif
! if ( ! $?PIGIRPC ) setenv PIGIRPC $PTOLEMY/bin.$ARCH/pigiRpc
if ( "$1" == "-debug" ) then
shift
--- 16,37 ----
exit 1
endif
! if ( ! $?PTOLEMY ) then
! setenv PTOLEMY ~ptolemy
! endif
! if ( ! $?OCTTOOLS ) then
! setenv OCTTOOLS $PTOLEMY
! endif
! if ( ! $?USER ) then
! setenv USER $LOGNAME
! endif
if ( ! $?ARCH ) then
setenv ARCH `$PTOLEMY/bin/arch`
endif
! if ( ! $?PIGIRPC ) then
! setenv PIGIRPC $PTOLEMY/bin.$ARCH/pigiRpc
! endif
if ( "$1" == "-debug" ) then
shift
*** ./bin/pigiEnv.csh Fri Dec 11 22:27:26 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/bin/pigiEnv.csh Mon Apr 12 17:54:27 1993
***************
*** 6,12 ****
#
# This is a modified version to support a PTOLEMY environment variable.
#
! # Version: @(#)pigiEnv.csh 1.4 12/11/92
# Copyright (c) 1990,1991,1992 The Regents of the University of California.
# All Rights Reserved.
#
--- 6,12 ----
#
# This is a modified version to support a PTOLEMY environment variable.
#
! # Version: @(#)pigiEnv.csh 1.5 1/19/93
# Copyright (c) 1990,1991,1992 The Regents of the University of California.
# All Rights Reserved.
#
***************
*** 17,22 ****
--- 17,24 ----
endif
if ( ! $?PTOLEMY ) setenv PTOLEMY ~ptolemy
+ if ( ! $?OCTTOOLS ) setenv OCTTOOLS $PTOLEMY
+ if ( ! $?USER ) setenv USER $LOGNAME
if ( ! $?ARCH ) then
setenv ARCH `$PTOLEMY/bin/arch`
endif
*** ./bin/prfacet Tue Dec 1 09:54:30 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/bin/prfacet Mon Apr 12 17:54:28 1993
***************
*** 1,15 ****
#!/bin/csh -f
# prfacet
! # @(#)prfacet 1.5 12/1/92
#
! # Print a facet using oct2ps to the printer specified by the environment
! # variable PRINTER.
#
- if ( ! $?PTOLEMY ) setenv PTOLEMY ~ptolemy
set path = ( $PTOLEMY/octtools/bin.$ARCH $path )
! if (!($?OCTTOOLS)) then
! setenv OCTTOOLS $PTOLEMY
! endif
! oct2ps -=T $PTOLEMY/lib/bw_patterns -f interface $*\:schematic | lpr -P$PRINTER
--- 1,48 ----
#!/bin/csh -f
# prfacet
! # SCCS info: %W% %G%
#
! # Using oct2ps, send a PostScript view of a facet to a printer or file.
#
+ # usage: prfacet [-TOFILE file] [oct2ps options] facet-name
+ #
+ # Generate a PostScript view of the specified facet.
+ # If the first argument to prfacet is "-TOFILE", the PostScript
+ # is saved to the specified file. If "-TOFILE" is not the first
+ # argument to prfacet, the PostScript is sent directly to the
+ # printer. The printer name must be specified by the environment
+ # variable PRINTER.
+ #
+ # The last option must be the pathname of the facet to be printed.
+ # All other options are passed to "oct2ps".
+ ##
+ ## Set shell and environment variables.
+ ##
+ if (!($?PTOLEMY)) setenv PTOLEMY ~ptolemy
+ if (!($?OCTTOOLS)) setenv OCTTOOLS $PTOLEMY
set path = ( $PTOLEMY/octtools/bin.$ARCH $path )
! set fixedArgs = ( -=T $PTOLEMY/lib/bw_patterns -f interface )
!
!
! ##
! ## Need two separate "if" lines below because we can't
! ## check $argv[1] whenever $#argv == 0.
! ##
! ## Need `expr` below because the simpler expression
! ## if ($argv[1] != "-TOFILE)
! ## fails whenever $argv[1] is "-x", "-f", etc.
! ##
! if ($#argv == 0) goto ToPrint
! if (`expr $argv[1] != "-TOFILE"`) goto ToPrint
! goto ToFile
!
!
! ToFile:
! oct2ps $fixedArgs $argv[3-]\:schematic > $argv[2]
! exit
!
! ToPrint:
! oct2ps $fixedArgs $argv[*]\:schematic | lpr -P$PRINTER
! exit
*** ./bin/ptman Fri Dec 11 11:40:52 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/bin/ptman Mon Apr 12 17:54:28 1993
***************
*** 1,6 ****
#!/bin/csh -f
! # @(#)ptman 1.6 12/11/92
# Print a man page for a Ptolemy star. Star can have its domain prepended to
# it (e.g., SDFLMS) or not (e.g., LMS). Looks through all the domains in
--- 1,6 ----
#!/bin/csh -f
! # @(#)ptman 1.7 2/8/93
# Print a man page for a Ptolemy star. Star can have its domain prepended to
# it (e.g., SDFLMS) or not (e.g., LMS). Looks through all the domains in
***************
*** 66,72 ****
# Find the star
cd $domaindir
if ($?PTMANPATH) then
! set domains = $PTMANPATH
else
set domains = `ls`
endif
--- 66,72 ----
# Find the star
cd $domaindir
if ($?PTMANPATH) then
! set domains = ($PTMANPATH)
else
set domains = `ls`
endif
*** ./bin/arch Thu Oct 15 11:22:09 1992
--- /imports/ptolemy/pt1/ptolemy/PTOLEMY_0.4.1/ptolemy/bin/arch Wed Apr 14 13:42:38 1993
***************
*** 1,5 ****
#! /bin/sh
! # @(#)arch 1.2 10/15/92
# shell script to figure out architecture, using C preprocessor
# works on the architectures we support.
/lib/cpp << EOF | grep '^X' | sed s/X//
--- 1,5 ----
#! /bin/sh
! # @(#)arch 1.3 4/14/93
# shell script to figure out architecture, using C preprocessor
# works on the architectures we support.
/lib/cpp << EOF | grep '^X' | sed s/X//
***************
*** 17,22 ****
Xmips
#endif
#ifdef hppa
! Xsnake
#endif
EOF
--- 17,22 ----
Xmips
#endif
#ifdef hppa
! Xhppa
#endif
EOF